tools: fix python installation
authorKeir Fraser <keir.fraser@citrix.com>
Tue, 7 Apr 2009 13:37:35 +0000 (14:37 +0100)
committerKeir Fraser <keir.fraser@citrix.com>
Tue, 7 Apr 2009 13:37:35 +0000 (14:37 +0100)
attached patch lets python install the modules into
DESTDIR/PREFIX as before, but lets python search
the modules in PREFIX rather DESTDIR/PREFIX.

This prevents failures about not finding python modules
after files have been installed into PREFIX.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
tools/pygrub/Makefile
tools/python/Makefile

index 48e982c075a6d26cbefd210dfdf4d985c8722281..0e30db481c5f41052f4f15d0ce8887846d5b11cc 100644 (file)
@@ -10,9 +10,8 @@ build:
 
 .PHONY: install
 ifndef XEN_PYTHON_NATIVE_INSTALL
-install: LIBPATH=$(shell PYTHONPATH=../python/xen/util python -c "import auxbin; print auxbin.libpath()")
 install: all
-       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install --home="$(DESTDIR)$(PREFIX)" --prefix="" --install-lib="$(DESTDIR)$(LIBDIR)/python"
+       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install --root="$(DESTDIR)" --home="$(PREFIX)" --prefix="" --force
        $(INSTALL_DIR) $(DESTDIR)/var/run/xend/boot
 else
 install: all
index 249bf634e79f9d50471ea094b3def80b56348a74..700640645bb4372cc7bf8130dab15a2dbb1c2361 100644 (file)
@@ -55,9 +55,8 @@ refresh-po: $(POTFILE)
 
 .PHONY: install
 ifndef XEN_PYTHON_NATIVE_INSTALL
-install: LIBPATH=$(shell PYTHONPATH=xen/util python -c "import auxbin; print auxbin.libpath()")
 install: install-messages install-dtd
-       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install --home="$(DESTDIR)$(PREFIX)" --prefix="" --force --install-lib="$(DESTDIR)$(LIBDIR)/python"
+       CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install --root="$(DESTDIR)" --home="$(PREFIX)" --prefix="" --force
 else
 install: install-messages install-dtd
        CC="$(CC)" CFLAGS="$(CFLAGS)" python setup.py install --root="$(DESTDIR)" --force